package cn.iocoder.an.module.mold.controller.admin.stockiorecords.vo;

import cn.iocoder.an.module.mold.dal.dataobject.account.AccountDO;
import cn.iocoder.an.module.mold.dal.dataobject.drawingno.DrawingNoDO;
import cn.iocoder.an.module.mold.dal.dataobject.storage.StorageDO;
import cn.iocoder.an.module.mold.dal.dataobject.warehouse.WarehouseDO;
import com.fhs.core.trans.anno.Trans;
import com.fhs.core.trans.constant.TransType;
import com.fhs.core.trans.vo.VO;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import cn.idev.excel.annotation.*;

@Schema(description = "管理后台 - 模具出入库记录 Response VO")
@Data
@ExcelIgnoreUnannotated
public class StockIoRecordsRespVO implements VO {

    @Schema(description = "主键", requiredMode = Schema.RequiredMode.REQUIRED, example = "13576")
    @ExcelProperty("主键")
    private Long id;

    @Schema(description = "出入库类型", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("出入库类型")
    private Integer inOrOut;

    @Schema(description = "单号", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("单号")
    private String code;

    @Schema(description = "部门Id", example = "30795")
    //@ExcelProperty("部门Id")
    @Trans(type = TransType.SIMPLE, targetClassName = "cn.iocoder.an.module.system.dal.dataobject.dept.DeptDO", fields = "name", ref = "deptName")
    private Long deptId;

    @Schema(description = "部门")
    @ExcelProperty("部门")
    private String deptName;

    @Schema(description = "仓库Id", example = "5197")
    //@ExcelProperty("仓库Id")
    @Trans(type = TransType.SIMPLE, target = WarehouseDO.class, fields = "name", ref = "warehouseName")
    private Long warehouseId;

    @Schema(description = "仓库")
    @ExcelProperty("仓库")
    private String warehouseName;

    @Schema(description = "储位id", example = "10558")
    //@ExcelProperty("储位id")
    @Trans(type = TransType.SIMPLE, target = StorageDO.class, fields = "name", ref = "storageName")
    private Long storageId;

    @Schema(description = "储位")
    @ExcelProperty("储位")
    private String storageName;

    @Schema(description = "模具台账ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "6570")
    @Trans(type = TransType.SIMPLE, target = AccountDO.class, fields = {"name", "code"}, refs = {"accountName","accountCode"})
    private Long accountId;

    @Schema(description = "模具名")
    @ExcelProperty("模具名称")
    private String accountName;

    @Schema(description = "模具编码")
    @ExcelProperty("模具名称")
    private String accountCode;

    @Schema(description = "图号id", requiredMode = Schema.RequiredMode.REQUIRED, example = "6468")
    @Trans(type = TransType.SIMPLE, target = DrawingNoDO.class, fields = "drawingNo", ref = "drawingNo")
    private Long drawingNoId;

    @Schema(description = "图号")
    @ExcelProperty("图号")
    private String drawingNo;

    @Schema(description = "操作人Id", example = "3359")
  //  @ExcelProperty("操作人")
    @Trans(type = TransType.SIMPLE, targetClassName = "cn.iocoder.an.module.system.dal.dataobject.user.AdminUserDO", fields = "nickname", ref = "operatorName")
    private Long operatorId;

    @Schema(description = "操作人")
    @ExcelProperty("归还人")
    private String operatorName;


    @Schema(description = "操作时间")
    @ExcelProperty("操作时间")
    private LocalDateTime operateTime;

    @Schema(description = "描述", example = "随便")
    @ExcelProperty("描述")
    private String description;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

}
